import pygame
import sys

WHITE=(255,255,255)
BLACK=(0,0,0)
RED=(255,0,0)
GREEN=(0,255,0)
BLUE=(0,0,255)

pygame.init()

size = width,height=600,600
screen=pygame.display.set_mode(size)

clock=pygame.time.Clock()
position=width//2,height//2

move=False

while True:
    for event in pygame.event.get(): 
        if event.type == pygame.QUIT:
            sys.exit()

        if event.type == pygame.MOUSEBUTTONDOWN:
            if event.button== 1:
                move=True
        if event.type == pygame.MOUSEBUTTONUP:
            if event.button== 1:
                move=False
        if move:
            position=pygame.mouse.get_pos()
            

    
    screen.fill(WHITE)
    pygame.draw.circle(screen,RED,position,20,1)
    pygame.draw.circle(screen,GREEN,position,40,1)
    pygame.draw.circle(screen,BLUE,position,60,1)
    pygame.display.flip()
    clock.tick(100)
